import { Entity, Column } from 'typeorm';
import { CommonEntity } from './common.entity'
// comment：评论表
@Entity('comment')
export class LikeEntity extends CommonEntity {
    @Column({
        type: 'int',
        name: 'user_id',
        comment: '用户id',
    })
    userId: number;

    @Column({
        type: 'int',
        name: 'posts_id',
        comment: '文章id',
    })
    postsId: number;

    @Column({
        type: 'varchar',
        length: 500,
        name: 'comment',
        comment: '评论内容',
    })
    comment: string;

    @Column({
        type: 'int',
        name: 'parent_id',
        comment: '父评论ID',
    })
    parentId: number;
}
